# $Id
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: damir <damir@archlinux.org>
# Contributor: Brice Carpentier <brice.carpentier@orange.fr>

pkgname=loudmouth
pkgver=1.5.3
pkgrel=1
pkgdesc="A lightweight Jabber client library written in C/Glib"
arch=('i686' 'x86_64')
license=('LGPL')
url="https://mcabber.com/"
depends=('glib2' 'gnutls' 'libidn' 'krb5')
makedepends=('intltool' 'pkgconfig' 'gtk-doc')
source=(https://mcabber.com/files/loudmouth/$pkgname-$pkgver.tar.bz2{,.asc})
sha256sums=('54329415cb1bacb783c20f5f1f975de4fc460165d0d8a1e3b789367b5f69d32c'
            'SKIP')
validpgpkeys=('EACADFF156849BC89653139E3C2900DEACB7FC95')

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  ./configure --prefix=/usr --disable-static
  sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
  make
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  make DESTDIR="${pkgdir}" install
}
